package com.zyx.camunda.service.servicetask;

import lombok.extern.slf4j.Slf4j;
import org.camunda.bpm.engine.delegate.DelegateExecution;
import org.camunda.bpm.engine.delegate.JavaDelegate;

/**
 * @author Yaxi.Zhang
 * @since 2022/11/19 16:05
 */
@Slf4j
public class ReserveRepairService implements JavaDelegate {

    @Override
    public void execute(DelegateExecution execution) throws Exception {
        System.out.println("进入到预约家电修理任务");
        String currentActivityName = execution.getCurrentActivityName();
        // 预约的具体调用
        //...
        String processDefinitionId = execution.getProcessDefinitionId();
        log.info("当前活动名称: [{}], 流程定义id: [{}]", currentActivityName, processDefinitionId);
    }

}
